#pragma once

#include <ECS/ECS.h>
#include <Box2D//Box2D.h>

struct Box2DWorldDef
{
	Box2DWorldDef();

	b2Vec2 gravity;
};

class Box2DWorld : public ECS::Component
{
	mtMETA_DEC;
public:
	Box2DWorld();
	bool initWith(Box2DWorldDef* def);

	static Box2DWorld* getInstance();

	void onUpdate();

	b2World* getWorld() const;
protected:
	b2World* _world;
};